﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Coslen.Framework.Logging.Services.Interfaces
{
    public interface ILoggingService
    {
        LoggingIndexModel GetLoggingIndexModel(string Period, string LoggerProviderName, string LogLevel, int? page, int? PageSize);
        
        /// <summary>
        /// Returns a single Log event
        /// </summary>
        /// <param name="logProviderName">Name of the log provider</param>
        /// <param name="id">Id of the log event as a string</param>
        /// <returns>A single Log event</returns>
        LogEventModel GetById(string logProviderName, string id);

        /// <summary>
        /// Clears log messages for a given date range and log level
        /// </summary>
        /// <param name="logProviderName">Name of the log provider</param>
        /// <param name="start">start date</param>
        /// <param name="end">end date</param>
        /// <param name="logLevels">The level of the log messages</param>
        void ClearLog(string logProviderName, DateTime start, DateTime end, string[] logLevels);

        /// <summary>
        /// Returns a Create Logging Manage Model with populated lists
        /// </summary>
        /// <returns></returns>
        LoggingManageModel GetNewLoggingManageModel();

        /// <summary>
        /// Repopulates the lists for the model
        /// </summary>
        /// <param name="model">Log Management Model</param>
        void PopulateListForLoggingManageModel(LoggingManageModel model);
    }
}
